<template>
  <h1>生命周期钩子</h1>
</template>

<script setup lang="ts">
import { onBeforeMount, onMounted } from 'vue'

onBeforeMount(() => {
  console.log('B.组件挂载前执行')
})

onMounted(() => {
  console.log('C.组件挂载后执行')
})

console.log('A.setup顶层的代码')
</script>
